﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.Design;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using System.Windows.Forms.Design;

namespace Computer
{
    [Designer(typeof(TongJi_EMS._TJ_Basic.TJ_BasicControlDesigner))]
  //  [System.Drawing.ToolboxBitmap(typeof(Label))]
    public partial class computer : TongJi_EMS._TJ_Basic.TJ_BasicControl
    {
        public computer()
        {
            InitializeComponent();
        }

        private void computer_Load(object sender, EventArgs e)
        {
            computer_Resize(sender, e);
        }

        private void computer_Paint(object sender, PaintEventArgs e)
        {
            //Zongbao.zongbao zb = new Zongbao.zongbao();
            //if (zb.Bol == "0")
            //{
            //    BackgroundImage = TongJi_EMS.Properties.Resources.计算机_关_;
            //}
            //else
            //{
            //    BackgroundImage = TongJi_EMS.Properties.Resources.计算机_开_;
            //}
            //e.Graphics.FillRectangle(Brushes.Green, 0, 0, x * 2f, y * 0.1f);
            //e.Graphics.FillRectangle(Brushes.Green, 0, y * 1.1f, x * 2f, y * 0.1f);
            //e.Graphics.FillRectangle(Brushes.Green, 0, 0, x * 0.1f, y * 1.2f);
            //e.Graphics.FillRectangle(Brushes.Green, x * 1.9f, 0, x * 0.1f, y * 1.2f);
            //e.Graphics.FillRectangle(Brushes.Gray, x * 0.1f, y * 0.1f, x * 1.8f, y);
            //e.Graphics.FillRectangle(Brushes.Green, x * 0.8f, y * 1.1f, x * 0.4f, y * 0.5f);
            //e.Graphics.FillEllipse(Brushes.Green, x * 0.2f, y * 1.6f, x * 1.6f, y * 0.4f);

        }

        private void computer_Resize(object sender, EventArgs e)
        {
            this.x = this.Width / 2;
            this.y = this.Height / 2;
            Refresh();
        }
    }
}